package com.projectName.www.po;

import com.projectName.www.dao.DishcatagoryDaoImpl;

import java.math.BigDecimal;
import java.sql.Timestamp;

public class Dish {

    private Integer dId;

    private String dame;

    private Integer typeid;//菜品类型

    private Timestamp dTime;//上架时间

    private BigDecimal dPrice;

    private int dNum=0;//数量

    private int dSum=0;//消耗的数量

    private String dImg;

    private Integer slrid;
    @Override
    public String toString() {

        return "Dish{" +
                "dId=" + dId +
                ", dame='" + dame + '\'' +
                ", type='" + new DishcatagoryDaoImpl().queryBydid(typeid) + '\'' +
                ", dTime=" + dTime +
                ", dPrice=" + dPrice +
                ", dNum=" + dNum +
                ", dSum=" + dSum +
                ", dImg='" + dImg +
                ", slrid='"+slrid+'\''+
                '}'+"\n";
    }

    public Dish() {
    }

    public Dish(String dame, Integer typeid, Timestamp dTime, BigDecimal dPrice, int dNum, int dSum, String dImg,Integer slrid) {
        this.dame = dame;
        this.typeid = typeid;
        this.dTime = dTime;
        this.dPrice = dPrice;
        this.dNum = dNum;
        this.dSum = dSum;
        this.dImg = dImg;
        this.slrid = slrid;
    }

    public Integer getSlrid() {
        return slrid;
    }

    public void setSlrid(Integer slrid) {
        this.slrid = slrid;
    }

    public Integer getdId() {
        return dId;
    }

    public void setdId(Integer dId) {
        this.dId = dId;
    }

    public String getDame() {
        return dame;
    }

    public void setDame(String dame) {
        this.dame = dame;
    }

    public Integer getTypeid() {
        return typeid;
    }

    public void setTypeid(Integer typeid) {
        this.typeid = typeid;
    }

    public Timestamp getdTime() {
        return dTime;
    }

    public void setdTime(Timestamp dTime) {
        this.dTime = dTime;
    }

    public BigDecimal getdPrice() {
        return dPrice;
    }

    public void setdPrice(BigDecimal dPrice) {
        this.dPrice = dPrice;
    }

    public int getdNum() {
        return dNum;
    }

    public void setdNum(int dNum) {
        this.dNum = dNum;
    }

    public int getdSum() {
        return dSum;
    }

    public void setdSum(int dSum) {
        this.dSum = dSum;
    }

    public String getdImg() {
        return dImg;
    }

    public void setdImg(String dImg) {
        this.dImg = dImg;
    }
}
